<!-- <!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>用户输入信息输出到网页</title>
    <script>
        console.log('在浏览器控制台输出信息'); //在浏览器控制台输出信息
        prompt("请输入") //弹出输入框
        alert('')
    </script>

    <body>

    </body>

</html> -->

<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>用户输入信息输出</title>
</head>

<body>
    <input type="text" id="userInput" placeholder="请输入信息">
    <button onclick="displayInput()">提交</button>
    <p id="output"></p>

    <script src="script--p015.js"></script>
</body>

</html>